package com.lian.community.async.handler;

import com.lian.community.async.EventHandler;
import com.lian.community.async.EventModel;
import com.lian.community.constant.EventType;
import org.springframework.stereotype.Component;

import java.util.Arrays;
import java.util.List;

@Component
public class LikeHandler implements EventHandler{

    @Override
    public void doHandler(EventModel eventModel) {

        // 这里是具体操作，比如说用户获得了赞，要给用户发个站内信等等
        System.out.println("like handler....");
    }

    @Override
    public List<EventType> geSupportEvent() {
        return Arrays.asList(EventType.LIKE);
    }
}
